package com.example.service;

import com.example.pojo.User;
import com.example.utils.UploadDataUtil;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.io.File;
import java.util.List;
import java.util.Map;

public interface UserService {
    public User login(String username, String password) throws Exception;

    public Integer updatePass(Integer uId, String password);

    public List<Map<String,Object>> getUserNewsList(Integer uId);

    public List<Map<String,Object>> getUserTopicList(Integer uId);

    public List<Map<String,Object>> getUserCollectionList(Integer uId);

    public Map<String,Object> getTopic(Integer tId);

    public Map<String,Object> getOtherUser(Integer uId);

    public String uploadAvatar(MultipartFile file, Integer uId, HttpServletRequest request);

    public Integer updateInfo(Integer uId, String nickname, String phone, String email);
}
